package it.unibo.imola.utils;

public class ExceptionUtils {

	public static String getMessageForErrorLogging(Exception e) {
		return e.getClass().getSimpleName() + ": " + e.getMessage() + "{" + e.getStackTrace()[e.getStackTrace().length - 1].toString() + "}";
	}

	public static String getMessageForDebugLogging(Exception e) {
		return org.apache.commons.lang3.exception.ExceptionUtils.getStackTrace(e);
	}


	public static String getMessageForDebugLogging(Throwable e) {
		return org.apache.commons.lang3.exception.ExceptionUtils.getStackTrace(e);
	}
}
